

tabOver = function() {
		var submenu = document.getElementById('tabSubmenu').document
				.getElementsByTagName('li');
		for ( var i = 0; i < submenu.length; i++) {
			submenu[i].onmouseover = function() {
				this.className += ' over';
			}
			submenu[i].onmouseout = function() {
				this.className = this.className.replace(new RegExp(' over\\b'),
						'');
	}}}

	if (window.attachEvent)
		window.attachEvent('onload', tabOver);
	


    
    $(function() {
		$("#tabs").tabs({
			ajaxOptions: {
				error: function(xhr, status, index, anchor) {
					$(anchor.hash).html("Couldn't load this tab. We'll try to fix this as soon as possible. If this wouldn't be a demo.");
				}
			}
		});
	});

    $(function() {
    	   $("#sortable").sortable({
    			opacity: '0.15',
        		forcePlaceholderSize: true
           });
    		$("#sortable").disableSelection();
    	});

    $(function() {
    	  
    	  $("#draggable").draggable({
          });
          
    	  $("#draggablea").draggable({
        	  containment: '#container',
        	  scroll: false,
        	  opacity: '0.15',
        	  scrollSensitivity: '40'
          });
    	  $("#draggablea").resizable({   
    	   maxHeight: 250,
    	   maxWidth: 350,
    	   minHeight: 150,
    	   minWidth: 200
    	  });
    	 });
    $(function() {
  	  $("#draggableb").draggable({
  	  	  containment: '#container',
  	  	  opacity: '0.15',
  	  	  scroll: false
  	  });
  	  $("#draggableb").resizable({   
  	   maxHeight: 250,
  	   maxWidth: 350,
  	   minHeight: 150,
  	   minWidth: 200
  	  });
  	 });